import { ref, computed } from 'vue'
import { defineStore } from 'pinia'
import * as fileApi from '@/api/fileApi'
import {ElMessage, ElNotification} from "element-plus";
import {usePreviewAudioStore} from "@/stores/previewAudioStore.js";
import {usePreviewInfoStore} from "@/stores/previewInfoStore.js";
import {usePreviewTextStore} from "@/stores/previewTextStore.js";
import {usePreviewVideoStore} from "@/stores/previewVideoStore.js";
import {usePreviewZipStore} from "@/stores/previewZipStore.js";

export const usePreviewStore = defineStore('previewStore', () => {

  const preShow = computed(() => {
    if(usePreviewAudioStore().show) return true
    if(usePreviewInfoStore().show) return true
    if(usePreviewInfoStore().show) return true
    if(usePreviewTextStore().show) return true
    if(usePreviewVideoStore().show) return true
    if(usePreviewZipStore().show) return true
    return false
  })

  return {preShow}

})
